in_systemd: Move one record back after skipping to the end#8917
Merged
edsiper merged 1 commit intofluent:masterfrom Jun 6, 2024
Merged
in_systemd: Move one record back after skipping to the end#8917edsiper merged 1 commit intofluent:masterfrom
edsiper merged 1 commit intofluent:masterfrom
Conversation
Member
|
@ardavast thanks for this contribution, would you please sign off the commits ? (DCO error) |
Signed-off-by: Ardavast Dayleryan <ardavast@noiseoverip.com>
d1b04dc to
6cec44d
Compare
Contributor
Author
Done |
leonardo-albertovich
approved these changes
Jun 5, 2024
Contributor
leonardo-albertovich
left a comment
There was a problem hiding this comment.
According to the manual this seems to be correct :
Note that these calls do not actually make any entry the new current entry, this needs to be done in a separate step with a subsequent [sd_journal_next(3)](https://manpages.debian.org/testing/libsystemd-dev/sd_journal_next.3.en.html) invocation (or a similar call).
|
I’m SO glad this got merged finally! This fix has existed since my PR #8396, but I was getting radio silence :( thank you so much for finally getting this merged |
3 tasks
This file contains hidden or bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Sign up for free
to join this conversation on GitHub.
Already have an account?
Sign in to comment
Add this suggestion to a batch that can be applied as a single commit.This suggestion is invalid because no changes were made to the code.Suggestions cannot be applied while the pull request is closed.Suggestions cannot be applied while viewing a subset of changes.Only one suggestion per line can be applied in a batch.Add this suggestion to a batch that can be applied as a single commit.Applying suggestions on deleted lines is not supported.You must change the existing code in this line in order to create a valid suggestion.Outdated suggestions cannot be applied.This suggestion has been applied or marked resolved.Suggestions cannot be applied from pending reviews.Suggestions cannot be applied on multi-line comments.Suggestions cannot be applied while the pull request is queued to merge.Suggestion cannot be applied right now. Please check back later.
On recent versions of systemd,
read_from_tail()doesn't work as expected unless followed with a call tosd_journal_previous().This can be tested with:
fluent-bit -i systemd -p read_from_tail=On -o stdoutThe command works on:
But it doesn't work on:
The following short program can also be used to test this (uncomment the line that calls sd_journal_previous() to see the difference):